Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

779 sdk readme fixes #781

Merged
merged 8 commits into from
Oct 13, 2023
Merged

779 sdk readme fixes #781

merged 8 commits into from
Oct 13, 2023

Conversation

mohammeds1992
Copy link
Collaborator

No description provided.

@mohammeds1992 mohammeds1992 linked an issue Oct 13, 2023 that may be closed by this pull request
@mohammeds1992 mohammeds1992 requested a review from Aman035 October 13, 2023 11:25
@github-actions
Copy link

  1. In line 19, there is a missing closing parenthesis at the end of the line. It should be closed after settings.origin.

  2. In line 20, there is a missing equal sign after decryptedPGPPrivateKey. It should be assigned the value of newUser.decryptedPrivateKey.

  3. In line 34, there is a missing closing bracket after the options object in PushStream.initialize().

  4. In line 35, there is a missing closing parenthesis after the options object in PushStream.initialize().

  5. In line 40, there is a missing closing brace after the if block.

  6. In line 43, there is a missing closing brace in the catch block.

  7. In line 47, the indentation of the async info() function is incorrect. It should be indented properly.

Apart from these issues, the code logic seems fine.

@github-actions
Copy link

  1. In the code block decryptedPGPPrivateKey = newUser.decryptedPrivateKey as string;, there is a missing semicolon at the end of the statement.

  2. There is a missing closing parenthesis ) at the end of the line return api;.

  3. The closing bracket } for the try block is missing.

  4. The info() method is declared but not implemented. It should have a function body.

Other than these issues, the code looks good.

@github-actions
Copy link

In file packages/restapi/src/lib/pushapi/PushAPI.ts:

  1. There is a missing closing curly brace for the else block starting at line 18. Add a closing } after line 20.

  2. The variable decryptedPGPPrivateKey is assigned the value of newUser.decryptedPrivateKey at line 22, but newUser.decryptedPrivateKey is not defined. It should be assigned newUser.decryptedPGPPrivateKey.

  3. The method initialize is called on PushStream, but PushStream is not imported anywhere in the code. Make sure to import the required module.

  4. There is a missing closing curly brace for the if block starting at line 30. Add a closing } after line 32.

  5. The return api; statement at line 35 is not indented properly. It should be at the same level of indentation as the try block.

  6. The method info() is not closed properly. Add a closing curly brace } at the end of the method.

@github-actions
Copy link

In the code provided, there are several mistakes and typos that need to be addressed:

  1. In the line decryptedPGPPrivateKey = newUser.decryptedPrivateKey as string;, there is a missing closing parenthesis at the end of the line. It should be decryptedPGPPrivateKey = newUser.decryptedPrivateKey as string;.

  2. In the line return api;, there is a missing closing parenthesis at the end of the line. It should be return api;}.

  3. In the line } catch (error) {, there is a missing closing brace after the catch block. It should be } catch (error) {}.

  4. The info() function is missing a closing brace at the end. It should be async info() {return await PUSH_USER.get({account: this.account,env: this.env,});}.

Apart from these minor issues, the code logic and structure appear to be correct.

@github-actions
Copy link

In the PushAPI.ts file, I've noticed the following issues:

  1. Close the create method in line 20 with a closing curly brace }.
  2. In line 21, you are trying to access decryptedPrivateKey as newUser.decryptedPrivateKey, but the object newUser does not have a property with that name. It seems that you meant to use decryptedPGPPrivateKey instead.
  3. In line 22, you are trying to access publicKey as newUser.publicKey, but again, the object newUser does not have a property with that name. It seems that you meant to use pgpPublicKey instead.
  4. In line 35, you are missing an opening curly brace { before the return api;.
  5. In line 41, you are missing an opening curly brace { after the throw new Error('Failed to initialize PushStream.');.
  6. In line 42, you are missing a closing curly brace } for the if statement block.
  7. The info method in lines 57-63 is missing a closing curly brace }.

Please make the necessary corrections.

@mohammeds1992 mohammeds1992 merged commit 12f5055 into main Oct 13, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SDK Readme fixes
2 participants